package com.yex.entity.otc;

import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.enums.IdType;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

/**
 * <p>
 * otc 订单表
 * </p>
 *
 * @author Little Liu
 * @since 2018-05-12
 */
@TableName("otc_order")
public class OtcOrder extends Model<OtcOrder> {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;
    /**
     * 委托 id
     */
    private Integer entrustId;
    /**
     * 用户id
     */
    private Integer userId;
    /**
     * 委托类型 0买入 1卖出
     */
    private Integer type;
    /**
     * 创建日期
     */
    private Date createDate;
    /**
     * 修改日期
     */
    private Date modifyDate;
    /**
     * 0未完成 1已完成 2冻结 3已支付 4超时取消 5买家取消 6客服取消
     */
    private Integer status;
    /**
     * 取消时间
     */
    private Date cancelDate;
    /**
     * 金额
     */
    private BigDecimal amount;
    /**
     * 数量
     */
    private BigDecimal countNum;
    /**
     * 订单号
     */
    private String orderNumber;
    /**
     * 支付方式 1支付宝 2微信 3银行卡
     */
    private Integer payMethod;
    /**
     * 支付时间
     */
    private Date payDate;
    /**
     * 收款时间
     */
    private Date collectPayDate;
    /**
     * 版本
     */
    private Integer version;
    /**
     * 价格
     */
    private BigDecimal prize;
    private BigDecimal rate;
    private BigDecimal fees;
    private BigDecimal entrustFees;
    private Date finishDate;
    private Integer orderMsg;
    /**
     * 币种ID
     */
    @TableField(exist=false)
    private Integer coinId;


    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Integer getEntrustId() {
        return entrustId;
    }

    public void setEntrustId(Integer entrustId) {
        this.entrustId = entrustId;
    }

    public Integer getUserId() {
        return userId;
    }

    public void setUserId(Integer userId) {
        this.userId = userId;
    }

    public Integer getType() {
        return type;
    }

    public void setType(Integer type) {
        this.type = type;
    }

    public Date getCreateDate() {
        return createDate;
    }

    public void setCreateDate(Date createDate) {
        this.createDate = createDate;
    }

    public Date getModifyDate() {
        return modifyDate;
    }

    public void setModifyDate(Date modifyDate) {
        this.modifyDate = modifyDate;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public Date getCancelDate() {
        return cancelDate;
    }

    public void setCancelDate(Date cancelDate) {
        this.cancelDate = cancelDate;
    }

    public BigDecimal getAmount() {
        return amount;
    }

    public void setAmount(BigDecimal amount) {
        this.amount = amount;
    }

    public BigDecimal getCountNum() {
        return countNum;
    }

    public void setCountNum(BigDecimal count) {
        this.countNum = count;
    }

    public String getOrderNumber() {
        return orderNumber;
    }

    public void setOrderNumber(String orderNumber) {
        this.orderNumber = orderNumber;
    }

    public Integer getPayMethod() {
        return payMethod;
    }

    public void setPayMethod(Integer payMethod) {
        this.payMethod = payMethod;
    }

    public Date getPayDate() {
        return payDate;
    }

    public void setPayDate(Date payDate) {
        this.payDate = payDate;
    }

    public Date getCollectPayDate() {
        return collectPayDate;
    }

    public void setCollectPayDate(Date collectPayDate) {
        this.collectPayDate = collectPayDate;
    }

    public Integer getVersion() {
        return version;
    }

    public void setVersion(Integer version) {
        this.version = version;
    }

    public BigDecimal getPrize() {
        return prize;
    }

    public void setPrize(BigDecimal prize) {
        this.prize = prize;
    }

    public BigDecimal getRate() {
        return rate;
    }

    public void setRate(BigDecimal rate) {
        this.rate = rate;
    }

    public BigDecimal getFees() {
        return fees;
    }

    public void setFees(BigDecimal fees) {
        this.fees = fees;
    }

    public BigDecimal getEntrustFees() {
        return entrustFees;
    }

    public void setEntrustFees(BigDecimal entrustFees) {
        this.entrustFees = entrustFees;
    }

    public Date getFinishDate() {
        return finishDate;
    }

    public void setFinishDate(Date finishDate) {
        this.finishDate = finishDate;
    }

    @Override
    protected Serializable pkVal() {
        return this.id;
    }

    public Integer getOrderMsg() {
        return orderMsg;
    }

    public void setOrderMsg(Integer orderMsg) {
        this.orderMsg = orderMsg;
    }

    public Integer getCoinId() {
		return coinId;
	}

	public void setCoinId(Integer coinId) {
		this.coinId = coinId;
	}

	@Override
    public String toString() {
        return "OtcOrder{" +
        ", id=" + id +
        ", entrustId=" + entrustId +
        ", userId=" + userId +
        ", type=" + type +
        ", createDate=" + createDate +
        ", modifyDate=" + modifyDate +
        ", status=" + status +
        ", cancelDate=" + cancelDate +
        ", amount=" + amount +
        ", count=" + countNum +
        ", orderNumber=" + orderNumber +
        ", payMethod=" + payMethod +
        ", payDate=" + payDate +
        ", collectPayDate=" + collectPayDate +
        ", version=" + version +
        ", prize=" + prize +
        "}";
    }
}
